<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="renderer" content="webkit">
    <title>[[${bargain.actName}]]</title>
    <meta name="keywords" content="LZY管理系统首页">
    <meta name="description" content="LZY管理系统首页">
	<meta content="yes" name="apple-mobile-web-app-capable"></meta>
	<meta content="black" name="apple-mobile-web-app-status-bar-style"></meta>
	<meta name="format-detection" content="telephone=no"></meta>
	<meta content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" name="viewport"></meta>
	<meta content="yes" name="full-screen"></meta>
	<meta content="true" name="x5-fullscreen"></meta>
	<meta content="application" name="browsermode"></meta>
	<meta name="apple-mobile-web-app-capable" content="yes">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link th:href="@{/content/bargain/default/css/index.css}" type="text/css" rel="stylesheet" />
	<script th:src="@{/content/bargain/default/js/jquery-1.9.1.min.js}" type="text/javascript"></script>
	<script th:src="@{/content/bargain/default/js/jquery.form.js}" type="text/javascript"></script>
	<script th:src="@{/content/bargain/default/js/static-page.js}" type="text/javascript"></script>
	<script th:src="@{/content/bargain/default/js/common.js}" type="text/javascript"></script>
	<script th:src="@{/content/bargain/default/js/wxcheck.js}" type="text/javascript"></script>
</head>
<body>
<div class="Nqqx_wrapper">
  <!--banner-->
    <div class="Nqqx_banner">
        <div class="Nqqx_banner_center" th:if="${bargain.productRemainNum gt 0}">
        	<div class="Nqqx_banner_center_zi">[[${bargain.showRate}]]个</div>
        	<div style="float: left;">千元蓝牙音箱</div>
        </div>
        <div class="Nqqx_banner_center_white">等您领取</div>
    	<div class="Nqqx_banner_center" style="color:red" th:if="${bargain.productRemainNum le 0}">
    		蓝牙音箱已抢光
    		<div class="Nqqx_banner_center_white" style="color:red">请继续关注下次活动</div>
        </div>
        
        <div id="showdemo" style="display: none;color: red;height: 50px;width: 60px">6666666666666666666666666666666666</div>
    	
    </div>
    
  <!--banner end-->
  <!--ceonter-->
  <div class="Nqqx_conter_form">
    <div class="Nqqx_conter">
      <div class="Nqqx_conter_jj">
        <div class="Nqqx_conter_jj_nr">
          <ul th:if="${bargainRegistration.awardsStatus eq '1'}">
           <li>[[${bargainRegistration.nickname}]]成功获得千元蓝牙音箱一部，心动不如行动，点击“我要参加”，浓情七夕，让爱发声~</li>
          </ul>
          <ul th:if="${bargainRegistration.awardsStatus ne '1'}">
            <li> 已有[[${recordListCount}]]位好友帮助[[${bargainRegistration.nickname}]]砍价</li>
            <li> 当前价：[[${bargainRegistration.productNewPrice}]]元</li>
            <li> 原价：[[${bargainRegistration.productPrice}]]元</li>
          </ul> 
        </div>
      </div>
      <!--按钮 帮我砍一刀  我要参加-->      
      <div class="btn_index_block btn_goods">
      	   <div class="btn_button1" th:if="${actStatus eq '0'}">
	            <a href="javascript:void(0)"><img th:src="@{/content/bargain/default/img/btn_hdjs.png}"></a>
	       </div >
	       <div th:if="${actStatus ne '0'}">
	         <div th:if="${bargain.productRemainNum le 0}">
		        <div class="btn_button">
		            <a disabled="true" ><img th:src="@{/content/bargain/default/img/btn_bwkyd.png}" /></a>
		        </div>
		        <div class="btn_button">
		           <a disabled="true" > <img th:src="@{/content/bargain/default/img/btn_wycj.png}" ></a>
		        </div>
		     </div>
		     <div th:if="${bargain.productRemainNum gt 0}">
		      	<div class="btn_button" >
		            <a href="javascript:bargain();"><img th:src="@{/content/bargain/default/img/btn_bwkyd.png}" /></a>
		        </div>
		        <div class="btn_button">
		           <a href="javascript:join();"> <img th:src="@{/content/bargain/default/img/btn_wycj.png}" ></a>
		        </div>
		     </div>    
	       </div> 
      </div>
      <!--按钮 end-->
      <!--亲友团-->
      <div class="qyt_tou">
        <ul>
          <li class="tou"><span>亲友团</span><span>砍掉价格</span><span>砍后价格</span></li>
        </ul>
      </div>
      <div class="qyt_tou">
        <ul id="recordtable">
          <li class="wei" th:each="item,iterStat:${recordList}">
          <span>[[${item.nickname}]]&nbsp;</span> 
          <span class="shanchu">[[${item.cutPrice}]]</span> 
          <span>[[${item.currPrice}]]</span>
          </li>
        </ul>
      </div>
      <div class="qyt_tou">
        <ul>
          <li class="wei"><span><a id="prev" href="#recordtableheader">上一页</a></span> <span id="current_page">1/110</span> <span><a id="next" href="#recordtableheader">下一页</a></span></li>
        </ul>
      </div>
      <!--亲友团 -->
      <!--活动详情-->
      <div class="hdxq_conter_nr_form">
        <dl class="hdxq_conter_nr">
          <dt class="hdxq_img1_title"><img th:src="@{/content/bargain/default/img/hdxq_title_img.png}" /></dt>
          <dd class="hdxq_wz"> 
              <span><b>如此高端的活动只给铁杆粉</b>：参与本活动前需关注“LZY”服务号。</span> 
              <span><b>我们拼的是手快和人气</b>：最先砍价至0元的两位用户可以各获得千元的电蟒CrazyBoa 2 Face便携式蓝牙音箱一个。</span> 
              <span>来，po几张我们大奖电蟒CrazyBoa 2 Face便携式蓝牙音箱的美照</span>
            <div class="cp_img1_form"><img th:src="@{/content/bargain/default/img/cp_img1.jpg}" /></div>
            <div class="cp_img1_form"><img th:src="@{/content/bargain/default/img/cp_img2.jpg}" /></div>
          </dd>
          <dt class="hdxq_img1_title"><img th:src="@{/content/bargain/default/img/hdjs_title_img.png}" /></dt>
        </dl>
      </div>
      <!--活动详情 end-->
      <!--活动介绍-->
      <div class="hdjs_conter_nr_form">
        <dl class="hdjs_conter_nr">
          <dt class="hdjs_conter_nr_title"><span><img th:src="@{/content/bargain/default/img/hdjs_title_bg.png}" /></span>
            <p>活动时间</p>
          </dt>
          <dd class="hdjs_conter_nr_wz_list"> <span> 2015年8月20日 00:00 — 8月 31日 00:00</span> </dd>
          <dt class="hdjs_conter_nr_title"><span><img th:src="@{/content/bargain/default/img/hdjs_title_bg.png}" /></span>
            <p>活动玩法</p>
          </dt>
          <dd class="hdjs_conter_nr_wz_list"> <span> 商品的初始价格为[[${bargainRegistration.productPrice}]]元。每个用户可随机帮别人砍掉[[${actRuleMin}]]-[[${actRuleMax}]]元的价格。</span> </dd>
          <dt class="hdjs_conter_nr_title"><span><img th:src="@{/content/bargain/default/img/hdjs_title_bg.png}" /></span>
            <p>奖励</p>
          </dt>
          <dl class="hdjs_conter_nr_wz_list">
            <span> 活动期间最先砍价至0元以下的两位用户即可赢取电蟒CrazyBoa 2 Face 便携式蓝牙音箱一个；</span>
          </dl>
          <dt class="hdjs_conter_nr_title"><span><img th:src="@{/content/bargain/default/img/hdjs_title_bg.png}" /></span>
            <p>特别提醒</p>
          </dt>
          <dd class="hdjs_conter_nr_wz_list"> 
          <span>1. 必须通过关注LZY才能参加该活动；</span> 
          <span>2. 活动期间每个微信ID仅能为另一个微信ID砍价一次；</span> 
          <span>3. 作弊刷票者将被取消活动资格。</span>
          <span>4. 音箱奖品颜色随机，以实际收到为准。</span>
          </dd>
        </dl>
      </div>
      <!--活动介绍 end-->
    </div>
  </div>
  <!--ceonter end-->
  <!--遮罩层-->
  <div id="act_bargain" style="opacity: 1; display:none;'display','none'" class="bombScreen">
    <!--遮罩层 end-->
    <!--砍价-->
    <div class="bombs fail1" style=" display:block;" >
	    <form id="actBargainForm" name="actBargainForm" action="/bargain/gobargain" method="post">
	    <input type="hidden" id="act_bargain_registrationId" name="registrationId" th:value="${bargainRegistration.id}"/>
	    <input type="hidden" id="act_bargain_openid" name="openid" th:value="${weixinDto.openid}"/>
	    <input type="hidden" id="act_bargain_subscribe" name="subscribe" th:value="${weixinDto.subscribe}"/>
	      <div class="inputcontent">
	        <p class="input_zdsbm_p">
	          <input id="act_bargain_nickname" name="nickname" th:value="${weixinDto.nickname}" placeholder="自动识别名字" type="text" class="zdsbmz_input">
	        </p>
	        <div class="">
	          <p class="input_yzm_p">
	            <input id="act_bargain_randCode" name="randCode" placeholder="填写验证码"  type="text" class="yzm_input">
	          </p>
	          <!-- <i class="yzm_img"><img id="randCodeImage" src="randCodeImage" /></i> </div> -->
	        <div class="zdsbmz_btn_from_nr"> <a href="javascript:bargain();" id="bargainSubmit" class="btn_bwkyd"><img th:src="@{/content/bargain/default/img/btn_bkj.png}" /></a> <a class="btn_wycj" href="javascript:popuphide('act_bargain')"><img th:src="@{/content/bargain/default/img/btn_qx.png}" /></a> </div>
	      </div>
      </form>
    </div>
  </div>
  <!--砍价 end-->
  
  <!--二维码-->
   <div id="act_focus" style="opacity: 1; display:none;" class="bombScreen">
	  <div class="bombs2 fail1" >
	    <div class="inputcontent2">
	    	<div class="erwm_form">
	    		<input type="hidden" name="act_focus_subscribe" id="act_focus_subscribe" th:value="${weixinDto.subscribe}"/>
				<input type="hidden" name="act_focus_actId" id="act_focus_actId" th:value="${weixinDto.actId}"/>
				<input type="hidden" name="act_focus_openid"  id="act_focus_openid" th:value="${weixinDto.openid}"/>
				<input type="hidden" name="act_focus_nickname"  id="act_focus_nickname" th:value="${weixinDto.nickname}"/>
				<input type="hidden" name="act_focus_jwid"  id="act_focus_jwid" th:value="${weixinDto.jwid}"/>
				<input type="hidden" name="act_focus_appid"  id="act_focus_appid" th:value="${appId}"/>
        		<div class="erwm_img"><img th:src="@{/content/bargain/default/img/tcc_erwmimg1.png}" /> <a href="javascript:void(0);"><img th:src="@{/content/bargain/default/img/tcc_erwmimg2.png}" /></a></div>
        		<i class="erwm_btn_qd"><a href="javascript:popuphide('act_focus');"><img th:src="@{/content/bargain/default/img/btn_qd.png}" /></a></i> 
           </div>
	    </div>
	  </div>
   </div>
  <!--二维码  end-->

  
    <!--砍价成功 start-->
    <div id="act_bargain_success"  class="bombScreen">
	    <!--提示-->
	    <div class="bombs7  fail1">
		      <div class="inputcontent7">
		         <div class="tstk_conter">
		             <span class="kstk_ts">恭喜您！</span>
		             <div class="tstk_conter_word">已成功帮好友砍掉<span id="act_cut_price">0</span>元</div>
		            <!--   <i class="tstk_conter_btn"><a th:href="javascript:popuphide('act_bargain_success');window.location.reload();"><img th:src="@{/content/bargain/default/img/btn_qd.png}" /></a></i>  -->
		         </div>
		    </div>
		  </div>
    </div>
    <!--砍价成功 end-->
  
    <!--提示框 start-->
    <div id="tip_msg" style="opacity: 1; display:none;" class="bombScreen">
	    <!--提示-->
	      <div class="bombs7  fail1"   style=" display:">
		      <div class="inputcontent7">
		         <div class="tstk_conter">
		             <span class="kstk_ts">提示：</span>
		             <div class="tstk_conter_word" id="tip_msg_content"></div>
		              <i class="tstk_conter_btn"><a href="javascript:popuphide('tip_msg')"><img th:src="@{/content/bargain/default/img/btn_qd.png}" /></a></i> 
		         </div>
		    </div>
		  </div>
    </div>
    <!--提示框 end-->
    
</div>
</body>
<!-- 微信分享功能 -->
<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
<script type="text/javascript">
	wx.config({
        debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来，若要查看传入的参数，可以在pc端打开，参数信息会通过log打出，仅在pc端时才会打印。
        appId: [[${appId}]], // 必填，公众号的唯一标识
        timestamp: [[${timestamp}]], // 必填，生成签名的时间戳
        nonceStr: [[${nonceStr}]], // 必填，生成签名的随机串
        signature: [[${signature}]],// 必填，签名，见附录1【必填：通过提供接口获取】
        jsApiList: [
    	        'checkJsApi',
    	        'onMenuShareTimeline',
    	        'onMenuShareAppMessage'
    	        ]
         // 必填，需要使用的JS接口列表，所有JS接口列表见附录2
    });
    wx.error(function(res){
    	// config信息验证失败会执行error函数，如签名过期导致验证失败，具体错误信息可以打开config的debug模式查看，也可以在返回的res参数中查看，对于SPA可以在这里更新签名。
    	
    	//签名失败跳转到错误页面
    });
    wx.ready(function () {
		var newHdUrl = [[${hdUrl}]]+ '?fxOpenid=' + [[${weixinDto.fxOpenid}]];
 	    wx.onMenuShareTimeline({
 	    	title: [[${bargain.actName}]], // 分享标题【必填】
            link: newHdUrl, // 分享链接【必填】
            imgUrl: [[${bargain.shortUrl}]], // 分享图标【必填】
            success: function () { 
                // 用户确认分享后执行的回调函数
            },
            cancel: function () { 
                // 用户取消分享后执行的回调函数
            }
        });
        
	  
        wx.onMenuShareAppMessage({
        	title: [[${bargain.actName}]], // 分享标题【必填】
            link: newHdUrl, // 分享链接【必填】
            imgUrl: [[${bargain.shortUrl}]], // 分享图标【必填】
            type: 'link', // 分享类型,music、video或link，不填默认为link【必填】
            dataUrl: '', // 如果type是music或video，则要提供数据链接，默认为空
            success: function () { 
                // 用户确认分享后执行的回调函数
				alert('已分享');
            },
            cancel: function () { 
                // 用户取消分享后执行的回调函数
				 alert('已取消');
            }
        });

  	});
	
</script>
</html>
